#include "UdpSocket.h"

#ifdef __linux
bool UdpSocket::Create(const Desc &desc)
{

    sock = socket(desc.af, desc.type, desc.protocol);

    if (-1 == sock)
    {
        LOGI("socket error", "");
        return false;
    }

    LOGI("socket success", "");
    return true;
}

void UdpSocket::Close()
{
    close(sock);
}
#endif 
